
<?php
require_once(getcwd()."/includes/settings.php");

	
		if (SERVER == '' || JUKE == '' || DB_NAME == '' || DB_USER == '' || DB_PASS == '' || CREDS == '' || DB_SERVER == '')
		{ 
		echo "There seems to be an issue with some variables, please rerun basic setup";
		die;
		}
else {

// 1. Create a database connection
$connection = mysql_connect(DB_SERVER,DB_USER,DB_PASS);
if (!$connection) {
	die("Database connection failed: " . mysql_error());
}

// 2. Select a database to use 
$db_select = mysql_select_db(DB_NAME,$connection);
if (!$db_select) {
	echo "Database selection failed: " . mysql_error() . "<br /><hr size='1' /> ";

	//die;
}
}
?>
